package ch4;

import java.util.Scanner;

public class ZouYe9 {
    public static void main(String[] args) {
        Scanner input=new Scanner(System.in);
        System.out.println("请输入工资：");
        double a=input.nextDouble();
        if (a<3500){
            a=0;
        }else if (a<8000){
            a=(a-3500)*0.05;
        }else if (a<=15000){
            a=4500*0.05+(a-8000)*0.1;
        }else if (a>15000){
            a=4500*0.05+7000*0.1+(a-15000)*0.15;
        }
        System.out.println(a+"元");
    }
}
